import request from '@/utils/request'

// 查询数据目录信息表列表
export function listCatagory(query) {
  return request({
    url: '/system/catagory/list',
    method: 'get',
    params: query
  })
}

export function listCatagoryData(query) {
  return request({
    url: '/system/catagory/listCatagoryData',
    method: 'get',
    params: query
  })
}

export function listCatagoryDataEffect(query) {
  return request({
    url: '/system/catagory/listCatagoryDataEffect',
    method: 'get',
    params: query
  })
}

export function getOrdernum(query) {
  return request({
    url: '/system/catagory/getOrdernum',
    method: 'get',
    params: query
  })
}

export function getCataCode(query) {
  return request({
    url: '/system/catagory/getCataCode',
    method: 'get',
    params: query
  })
}

// 查询数据目录信息表详细
export function getCatagory(uuid) {
  return request({
    url: '/system/catagory/' + uuid,
    method: 'get'
  })
}

// 新增数据目录信息表
export function addCatagory(data) {
  return request({
    url: '/system/catagory',
    method: 'post',
    data: data
  })
}

// 修改数据目录信息表
export function updateCatagory(data) {
  return request({
    url: '/system/catagory',
    method: 'put',
    data: data
  })
}

// 删除数据目录信息表
export function delCatagory(uuid) {
  return request({
    url: '/system/catagory/' + uuid,
    method: 'delete'
  })
}

// 新建存储筒
export function createBucket(data) {
  return request({
    url: '/system/catagory/createBucket',
    method: 'post',
    data: data
  })
}

// 删除存储筒
export function deleteBucket(data) {
  return request({
    url: '/system/catagory/deleteBucket',
    method: 'post',
    data: data
  })
}

export function saveDatasetCatagory(data) {
  return request({
    url: '/system/catagory/saveDatasetCatagory',
    method: 'post',
    data: data
  })
}

export function getTreeRootData(query) {
  return request({
    url: '/system/catagory/getTreeRootData',
    method: 'get'
  })
}

export function getBucketObjects(query) {
  return request({
    url: '/system/catagory/getBucketObjects',
    method: 'get',
    params: query
  })
}

export function deleteBucketObject(data) {
  return request({
    url: '/system/catagory/deleteBucketObject',
    method: 'post',
    data: data
  })
}

export function getBucketFolderObjects(data) {
  return request({
    url: '/system/catagory/getBucketFolderObjects',
    method: 'post',
    data: data
  })
}

export function getAllPoints(data) {
  return request({
    url: '/system/catagory/getAllPoints',
    method: 'post',
    data: data
  })
}